When the execution of an application switches from a first context to a second context, it is necessary to save the state information associated with the first context. When the second context is completed, the state information associated with the first context must be restored so that execution of the first context may be completed. The state information to be stored and restored may include register values, pointers, program counters, condition codes and the like.
There are different techniques to recover state information from a graphics processing unit. One approach is to use a central register control block and RAM chains. The problem with this approach is that RAM chains require dedicated wires to each RAM storing state information. This architecture becomes unwieldy. In addition, relying upon register accesses to transfer state information is relatively slow. Another approach to recover state information from a graphics processing unit is to route the state information from the processors of a graphics processing unit to a frame buffer. This approach results in long, parallel storage paths. While this approach provides improved data transfer speeds, it is relatively complex.
It would be desirable to provide a new mechanism for storing and restoring state information in the event of a context switch in a graphics processing unit.